<template>
  <div class="params mb-3" >
    <el-form
      :model="form"
      :inline="true"
    >
      <el-form-item label="客户姓名:">
        <el-input v-model="form.customerName" :size="formSize" placeholder="请输入客户姓名"></el-input>
      </el-form-item>
      <el-form-item label="客户电话:">
        <el-input v-model="form.customerMobile" :size="formSize" placeholder="请输入客户电话"></el-input>
      </el-form-item>
      <el-form-item >
        <el-button type="primary" icon="el-icon-search" :size="formSize">查询</el-button>
      </el-form-item>
    </el-form>

  </div>
</template>

<script>
export default {

  data() {
    return {
      form: {
        customerName: '',
        customerMobile: ''
      },
      timeSlot: [new Date(), new Date()],
      formSize:'small'
    }
  },

  async mounted() {
    this.search()
  },
  methods: {
    search() {
      const form = Object.assign({}, this.form)

      this.$emit('search', form)
    },
    addContract() {
      this.$router.push({
        name: 'addContract'
      })
    }
  }
}
</script>

<style lang="scss" scoped>
    .params{
        padding-top: 20px;
        .wrapping{
            display: inline-block;
            margin-right: 10px;
            margin-bottom: 10px;
        }
    }
</style>
